﻿#ifndef INJECTORDATA_H
#define INJECTORDATA_H
#include <QString>

struct InjectorSetting
{
    int inject_period;
    int comm_period;

    int inject_volume;

    int max_current;
    int min_volt;

    bool operator==(const InjectorSetting& rhs)
    {
        return inject_period == rhs.inject_period &&
               comm_period == rhs.comm_period &&
               inject_volume == rhs.inject_volume &&
               max_current == rhs.max_current &&
               min_volt == rhs.min_volt;
    }
    bool operator!=(const InjectorSetting& rhs)
    {
        return !operator==(rhs);
    }
};

struct InjectorData
{
    uint id;
    int ip;
    QString name;
    QString position;
    int status = 0;
    int battery = 100;
    int oil = 100;
    InjectorSetting settings;
};

#endif // INJECTORDATA_H
